Skip to content

Dev/19: ServiceInstanceListSupplierBuilder design basic implementation #24

Merged
Johnny850807 merged 27 commits intomainfrom
dev/19
Nov 13, 2020
Merged

Dev/19: ServiceInstanceListSupplierBuilder design basic implementation #24
Johnny850807 merged 27 commits intomainfrom
dev/19

Conversation

@Johnny850807
Copy link
Copy Markdown
Collaborator

@Johnny850807 Johnny850807 commented Nov 6, 2020

Description

  • Basic ServiceInstanceListSupplierBuilder implementation
    • Also Include the decorators DelegatingServiceInstanceListSupplier and CachingServiceInstanceListSupplier

image

  • A CacheManager basic implementation helps handle caching get/put in a fluent way, for example
    cache_manager.get(CACHE_NAME).on_cache_miss(lambda: retrieve_value())
    • CacheManager is used by CachingServiceInstanceListSupplier

Currently, we do not optimize the caching behavior e.g. evict-and-replacement.

@Ricky587
Copy link
Copy Markdown

Ricky587 commented Nov 6, 2020

btw what happened to your pre-commit check?

@Johnny850807
Copy link
Copy Markdown
Collaborator Author

Johnny850807 commented Nov 6, 2020

btw what happened to your pre-commit check?

@Ricky587 Since my PRs are sequential, dev/20 based on dev/19, dev/19 based on dev/17, dev/17 based on main
and our CI workflow only triggered when PR is based on the [main] branch, so the CI is not working in these PRs.

BTW the pre-commit hook works very well locally, it's really convenient.

@Johnny850807 Johnny850807 requested review from Ricky587, benbenbang and woolninesun and removed request for benbenbang and woolninesun November 7, 2020 04:49
@Johnny850807
Copy link
Copy Markdown
Collaborator Author

Revision Done

Base automatically changed from dev/17 to main November 11, 2020 12:27
@woolninesun
Copy link
Copy Markdown

LGTM for pythonic

@benbenbang
Copy link
Copy Markdown
Collaborator

Go go ;)

@Johnny850807 Johnny850807 merged commit 7fb4066 into main Nov 13, 2020
@Johnny850807 Johnny850807 deleted the dev/19 branch November 13, 2020 04:25
Copy link
Copy Markdown
Contributor

@TsengMJ TsengMJ left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed

ck6990ck6990 pushed a commit that referenced this pull request Nov 18, 2020
#24)

* 🍺 implement DiscoveryClient design

* Add more comments

* Modify some functional operation concerning performance

* 📝 add typing and docstrings

* Make some fields private

* Fix naming

* pending discussion: next+filter vs list comprehension

* 🎨 Add type checking syntax

* improve filter_get_first utils

* ✨ FixedServiceInstanceListSupplier completed

* ✨ CachingServiceInstanceListSupplier completed

* 🎨 Add type checking syntax

* 🎨 Add NoneTypeError and some type checking

* 🍺 implement DiscoveryClient design

* Add more comments

* Modify some functional operation concerning performance

* 📝 add typing and docstrings

* Make some fields private

* Fix naming

* pending discussion: next+filter vs list comprehension

* 🎨 Add type checking syntax

* improve filter_get_first utils

* 🚚 Modify the package layout, rooted from spring_cloud

* add utils/validate
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Spring Cloud commons ServiceInstanceListSupplier design implementation

5 participants